<?php
/**
 * @package		Joomla.Site
 * @subpackage	mod_articles_news
 * @copyright	Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved.
 * @license		GNU General Public License version 2 or later; see LICENSE.txt
 */

// no direct access
defined('_JEXEC') or die;

?>
<script language="javascript">
window.addEvent('domready', function(){
    var show = function(selector){
        selector.setStyle('display', '');
    };
	
	var hide = function(selector){
        selector.setStyle('display', 'none');
    };
	
    // We are setting the opacity of the element to 0.5 and adding two events
	/*
	mouse over
    $$('td.mficquotes-td').addEvents({
        mouseenter: function(){
			hide($$('div[class*=mficquotes-td-0]'));
            show($$('div[class*=' + this.get('id') + ']'));
        },
        mouseleave: function(){
            // Morphes back to the original style
			show($$('div[class*=mficquotes-td-0]'));
           hide($$('div[class*=' + this.get('id') + ']'));
        }
    });
	*/
	/*
	click
	*/
    $$('td.mficquotes-td').addEvents({
        click: function(){
			hide($$('div[class*=mficquotes-td]'));
            show($$('div[class*=' + this.get('id') + ']'));
        }
    });

});
</script>
<div id="mficquotes-circle">
<table style="width: 100%;" border="0">
<tbody>
<tr>
<td align="center" valign="middle" width="20%">&nbsp;</td>
<td align="center" valign="middle" width="20%">&nbsp;</td>
<td align="center" valign="middle" width="20%" id="mficquotes-td-2" class="mficquotes-td">
<?php 
$item = $list[2];
require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_item');
?>
</td>
<td align="center" valign="middle" width="20%">&nbsp;</td>
<td align="center" valign="middle" width="20%">&nbsp;</td>
</tr>
<tr>
<td align="center" valign="middle"  id="mficquotes-td-1" class="mficquotes-td">
<?php 
$item = $list[1];
require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_item');
?>
</td>
<td rowspan="3" colspan="3" align="center" valign="middle">
	<?php $item = $list[0]; ?>
	<div class="mficquotes-text mficquotes-td-0">
	<?php require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_text');?>
	</div>

<?php for ($i = 1, $n = count($list); $i < $n; $i ++) :
	$item = $list[$i]; ?>
	<div class="mficquotes-text mficquotes-td-<?php echo ($i)?>" style="display: none;">
	<?php require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_text');?>
	</div>
<?php endfor; ?>

</td>
<td align="center" valign="middle"  id="mficquotes-td-3" class="mficquotes-td">
<?php 
$item = $list[3];
require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_item');
?>
</td>
</tr>
<tr>
<td align="center" valign="middle">&nbsp;</td>
<td align="center" valign="middle">&nbsp;</td>
</tr>
<tr>
<td align="center" valign="middle"  id="mficquotes-td-6" class="mficquotes-td">
<?php 
$item = $list[6];
require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_item');
?>
</td>
<td align="center" valign="middle"  id="mficquotes-td-4" class="mficquotes-td">
<?php 
$item = $list[4];
require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_item');
?>
</td>
</tr>
<tr>
<td align="center" valign="middle" width="20%">&nbsp;</td>
<td align="center" valign="middle" width="20%">&nbsp;</td>
<td align="center" valign="middle" width="20%" id="mficquotes-td-5" class="mficquotes-td">
<?php 
$item = $list[5];
require JModuleHelper::getLayoutPath('mod_mficquotes', '_td_item');
?>
</td>
<td align="center" valign="middle" width="20%">&nbsp;</td>
<td align="center" valign="middle" width="20%">&nbsp;</td>
</tr>
</tbody>
</table>
</div>
